{literal}

<script>

$(document).ready(
	function(){
		$('tr.item-row', '#list-table').hover(
				function(){
					$('span.management-controls', $(this)).show();
				},
				function(){
					$('span.management-controls', $(this)).hide();
				}				
		)			
	}
);

</script>

{/literal}

{$menu}
{if count($list) > 0}
	<table id="list-table" class="ow_stdmargin ow_full ow_table_1">
		<tr>
			<th>Comment</th>
			<th class="ow_center" width="100">Date</th>
			<th width="60"></th>
		</tr>
		{foreach from=$list item='item'}
			<tr  class=" item-row {cycle name=comments values="ow_alt1"}">
				<td>
					{assign var='userId' value=$item.userId}
					{capture assign='authorLink'}{user_link name=$displaynameList[$userId] username=$usernameList[$userId]}{/capture}
					{assign var=id value=$item.entityId}
					{capture assign='info_string'}{$authorLink} {text key="blogs+on"} <a href="{blog_post_url id=$item.entityId}">{$postList[$id]->title}</a>{/capture}
					{decorator name='ipc'
						infoString=$info_string 
						content=$item.message 
						imageSrc=$avatarUrlList[$userId]
                        imageTitle=$usernameList[$userId]
						toolbar=''
						displayName=$displaynameList[$userId]}
				</td>
				<td class="ow_small ow_center">{format_date timestamp=$item.createStamp}</td>
				<td class="ow_nowrap ow_center">
					<div style=" width: 74px;">
						<span class="management-controls" style="display: none;">
							<a href="{url_for for="BLOGS_CTRL_ManagementComment:deleteComment:[id=>`$item.id`]"}?back-to={$thisUrl}" class="ow_lbutton ow_red">{text key='blogs+blog_manage_delete'}</a>
						</span>
					</div>
				</td>
			</tr>
		{/foreach}
	</table>
{else}
		<div class="ow_center">
			{text key='base+comment_no_comments'}
		</div>
{/if}		
{$paging}